<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>浮动练习</title>

    <style>
        .inner{
            height: 400px;
            width: 400px;
            background-color: gray;
            border: 1px solid orange;
        }

        .box{
            height: 100px;
            width: 100px;
            border: 2px solid pink;
            margin: 10px;
        }
        .box1{
            background-color: aqua;
            float: right;
        }
        .box2{
            background-color: red;
        }
        .box3{
            background-color: rebeccapurple;
        }
    </style>
</head>
<body>
    
    <div class="inner">
    <div class="box box1">box1</div>
    <div class="box box2">box2</div>
    <div class="box box3">box3</div>
    </div>
</body>
</html>